import type { RouteRecordRaw } from 'vue-router';

const routes: RouteRecordRaw[] = [
  {
    path: '/',
    redirect: '/rt/rcs2'
  },
  {
    path: '/login',
    component: () => import('pages/LoginPage.vue')
  },
  {
    path: '/rt',
    component: () => import('pages/Rt.vue'),
    children: [
      {
        path: 'rcs2',
        component: () => import('pages/Rcs2.vue')
      },
      {
        path: 'agvList',
        component: () => import('pages/AgvList.vue'),
        children: [
          {
            path: ':ip',
            component: () => import('pages/AgvTabs.vue'),
            children: [
              {
                path: 'rc',
                component: () => import('pages/AgvTabItem.vue')
              }
            ]
          }
        ]
      }

    ]
  },

  // but you can also remove it
  {
    path: '/:catchAll(.*)*',
    component: () => import('pages/ErrorNotFound.vue')
  }
];

export default routes;
